import pygame
import sys
pygame.init()
s=pygame.display.set_mode((1000,600))
name=["bg","for","list","random","function","box","lose","win","m0","m1"]
k=[]
for i in name:
   p=pygame.image.load("images/%s.png"%(i))
   k.append(p)
s.blit(k[0],(0,0))
pygame.display.update()
while 1:
    for e in pygame.event.get():
        if e.type==pygame.QUIT:
            sys.exit()

        if e.type==pygame.MOUSEMOTION:
            s.blit(k[0],(0,0))
            x=e.pos[0]
            y=e.pos[1]
            print("x坐标%d,y坐标%d"%(x,y))
            # if 230<x<340 and 105<y<250:
            #     s.blit(k[2],(0,0))

            pygame.display.update()